package org.dhbw.jee.persistence.dataAccess;

import java.util.List;

public interface IDataAccessObject {

	public abstract <T, R> T getSingle(Class<T> type, R key);

	public abstract <T> List<T> getAll(Class<T> type);

	public abstract <T> T getSingleByQuery(Class<T> type, String query, Object... params);

	public abstract <T> List<T> getAllByQuery(Class<T> type, String query, Object... params);

	public <T> boolean persist(T object);

	public <T> boolean delete(T object);

	public <T> boolean update(T object);
}
